<?php 
   JLoader::register('PJobpositionModelPosition', OC::$SERVERROOT.'/apps/jobposition/lib/position.php');

   $user = PFactory::getMasterUser();
   $jobid = JRequest::getInt('job_id',0);

   if(!PCompanyHelper::ownJobId($jobid)) {
      echo '您无权访问该资源';
      exit; 
   }
   

   $model = new PJobpositionModelPosition();
   $jobdetails = $model->showJobdetails($jobid);
   if($jobdetails->system){
      echo '该职位是系统上传职位，不允许修改匹配设置。';
      exit; 
   }

   $part_postjob = new OCP\Template('jobposition', 'part.postjob', '');
   $part_postjob->assign('type','edit');
   $part_postjob->assign('jobdetails', $jobdetails);
   $part_postjob->printPage(); 


